 ///<reference path="references.js" />

if ( window.irinori === undefined ) {
	//var irinori = {};
    window.irinori = {};
}

irinori.Player = function (a_name) 
{
    if (arguments.length != 1) {
        throw "Player not created properly";
    }

    this.m_robot;

    this.m_name = a_name;

    this.m_cards = [];
}

irinori.Player.prototype.initRobot = function(a_x, a_y, a_direction, a_type)
{
    

    if (a_direction > 3)
    {
        a_direction = 3;
    }
    else if (a_direction < 0)
    {
        a_direction = 0;
    }

    this.m_robot = new irinori.Robot(a_x, a_y, a_direction, a_type || 0);
}